package gazpachito.examples.patterns.methodTemplate.business;

import gazpachito.examples.patterns.methodTemplate.api.TemplateDTO;
import gazpachito.examples.patterns.methodTemplate.business.exceptions.BusinessException;

/**
 * This Business Interfaz just give us a simple API to apply to every interfaz
 * we can need or implement in this example.
 * 
 * @author jvillar
 * 
 * @param <S>
 */
public interface TemplateBusiness<S extends TemplateDTO> {

	/**
	 * Method to validate an element
	 * 
	 * @param element
	 */
	void validate(S element) throws BusinessException;

	/**
	 * Method to execute an element
	 * 
	 * @param element
	 */
	void execute(S element) throws BusinessException;

}
